# Virtual Router Simulator 
#
# Copyright (C) 2009-2010 VRSim Project
# Author: Choonho Son <choonho@kt.com>
# URL: <http://vrsim.googlecode.com>
# For license information, see LICENSE.TXT
#

import VRSim.Globals as globals
from VRSim.Node.XML import XML
from VRSim.Utils import debug

class PhysNode(XML):
    def __init__(self,  nodeid):
        self.nodeid = nodeid
        self.hostname = "PhysNode"
        self.model = "AbstractNode"
        self.geoX = 0.0
        self.geoY = 0.0
        self.posX = 0.0
        self.posY = 0.0
        
        self.state = globals.STOP

        #XML
        XML.__init__(self, "domain")
        
#    def start(self):
#        pass
        
#    def stop(self):
#        pass
    
#    def suspend(self):
#        pass
        
    def updateHostname(self,  name):
        self.hostname = name

    def setGeoPos(self,  x,  y):
        self.geoX = x
        self.geoY = y
        
    def setPos(self,  x,  y):
        self.posX = x
        self.posY = y
        
   
